package com.yoona.system.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.util.Date;

/**
 * @Email: m15602498163@163.com
 * @Author: yoonada
 * @Date: 2020/9/21
 * @Time: 7:12 下午
 * @Msg:
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class DynamicComments implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 评论id
     */
    @TableId(type = IdType.UUID)
    private String commentId;

    /**
     * 动态id
     */
    private String dynamicId;

    /**
     * 评论内容
     */
    private String commentContent;

    /**
     * 评论者id
     */
    private String commenterId;

    /**
     * 评论者头像
     */
    private String commenterAvatarUrl;

    /**
     * 评论者昵称
     */
    private String commenterNickName;

    /**
     * 父级评论id
     */
    private String parentCommentId;

    /**
     * 父级评论者id
     */
    private String parentCommenterId;

    /**
     * 父级评论者头像
     */
    private String parentCommenterAvatarUrl;

    /**
     * 父级评论者昵称
     */
    private String parentCommenterNickName;

    /**
     * 评论能否被删除(默认为0,不能;为1时,可以被删除)
     */
    private int commentCanDelete;

    /**
     * 创建时间
     */
    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    private Date commentCreateTime;

    @TableField(exist = false)
    private String passCommentCreateTime;

    @TableField(exist = false)
    private Dynamic dynamic;

}
